@import "../../../base/display/set2-template";
@import "../../../slider";
@import "../../../grid";

@font-face {
  font-family: 'Kanit';
  src: url('../../fonts/google/Kanit.ttf') format('truetype');
  font-weight: normal;
  font-style: normal;
}

$quote-font: "Kanit";

@font-face {
  font-family: '#{$navigation-icon}';
  src: url('../../fonts/default-template/tvo-default-t-icons.eot?62scwa');
  src: url('../../fonts/default-template/tvo-default-t-icons.eot?#iefix62scwa') format('embedded-opentype'),
  url('../../fonts/default-template/tvo-default-t-icons.woff?62scwa') format('woff'),
  url('../../fonts/default-template/tvo-default-t-icons.ttf?62scwa') format('truetype'),
  url('../../fonts/default-template/tvo-default-t-icons.svg?62scwa#tlp-icon-authorfocused') format('svg');
  font-weight: normal;
  font-style: normal;
}

.tvo-#{$template-name}-template {
  &.tvo-testimonials-display-slider {
    @include tvo-relative;
    padding: 0 $slider-spacing;

    .tvo-item-grid {
      margin-left: 0;
      margin-right: 0;
    }

    .tvo-testimonial-display-item {
      padding: $slider-spacing 0;

      h4 {
        color: $title-color-large;
        font-size: $title-size-large;
        font-weight: $title-weight-large;
        line-height: $title-line-height-large;
        margin-bottom: $title-small-margin-bottom;
        margin-top: 20px;
      }

      p {
        color: $font-color;
        font-size: $font-size;
        font-weight: $font-weight;
        line-height: $font-line-height;
        margin-bottom: $font-margin-bottom;
      }
    }

    .tvo-testimonial-name {
      color: $name-color-light;
      font-size: $name-size;
      font-weight: $name-weight;
      line-height: $name-line-height;
    }

    .tvo-testimonial-role {
      color: $name-color-light;
      font-size: $job-size;
      font-weight: $job-weight;
      line-height: $job-line-height;

      a {
        color: inherit;
        text-decoration: none;
      }
    }

    .tvo-image-wrapper {
      min-width: $image-size;
    }

    .tvo-testimonial-quote {
      position: relative;
      left: 0;
      top: -20px;

      &:before {
        font-family: $quote-font;
      }
    }

    .tvo-testimonial-content {
      -webkit-flex: 1;
      flex: 1;
      padding: 0 $grid-item-padding-side 0 ($slider-spacing*1.5);
    }

    .thrlider-nav {
      margin: 0 auto (($slider-spacing -  $bullet-size) * 0.5);
      text-align: center;
      position: relative;
      z-index: 1;
    }

    .thrlider-navItem {
      @media (min-width: 768px) {
        display: inline-block;
        float: none;
      }

      &:hover {
        .thrlider-navItem-inner {
          background: $bullet-bg-hover;
        }
      }

      .thrlider-navItem-inner {
        border-radius: $bullet-border-radius;
        background: $bullet-bg;
        display: block;
        height: $bullet-size;
        margin: 0 5px;
        width: $bullet-size;
      }
    }
  }

  [id*='thrlider'] {
    &:after {
      background: $navigation-bg;
      border-bottom: 1px solid $testimonial-info-border;
      content: '';
      display: block;
      height: $slider-spacing;
      position: absolute;
      left: 0;
      right: 0;
      bottom: 0;
    }
  }

  .tvo-testimonial-display-item.custom-set6-slider {
    hr {
      margin: 20px auto;
      background-color: #fff;
    }

    .quote-title-holder {
      position: relative;
      margin-top: 75px;

      hr {
        margin: 0 auto;
      }

      h4 {
        font-size: 24px;
        font-weight: 600;
        letter-spacing: 1.5px;
        text-align: left;
      }

      .tvo-testimonial-quote {
      }
    }

    padding: 15px 35px 35px 35px;
    text-align: left;

    .tvo-testimonial-content {
      padding: 0;
    }

    .tvo-testimonial-info {
      padding-top: 0;

      span {
        font-size: 16px;
        text-transform: none;
        display: inline-block;
      }
    }

    .tvo-testimonial-quote {
    }
  }
}

.tvo-set2-template.tvo-testimonials-display-slider .thrlider-nav {
  margin: 0;
  padding: 25px 0 0;
}

.tvo-set2-template [id*='thrlider']:after {
  border-bottom: none;
}

.tvo-set2-template.tvo-testimonials-display-slider .thrlider-nav-wrapper {
  margin-left: 111px !important;
}

.tvo-set2-template.tvo-testimonials-display-slider {
  .thrv-navigation-wrapper {
    position: relative;
    z-index: 2;
  }

  .thrlider-prev, .thrlider-next {
    &:focus, &:hover {
      color: #0d0d0d;
    }

    top: 100%;
    position: relative;
    z-index: 2;
    line-height: 72px;
    display: inline-block;
  }

  .thrlider-prev {
    float: left;
  }

  .thrlider-next {
    float: right;
  }
}

.thrlider-slider {
  height: auto;
}

.tvo-set2-template.tve_orange .thrlider-nav .thrlider-navItem.thrlider-active .thrlider-navItem-inner {
  background: #666666;
}

// slider design on iphone
@media only screen and (max-device-width: 768px) {
  .tvo-set2-template .tvo-testimonial-display-item.custom-set6-slider {
    /* max-height: 375px; this just breaks the code in a thousand little pieces ;) */
  }
  .tvo-set2-template.tvo-testimonials-display-slider .thrlider-nav-wrapper {
  }
  .tvo-set2-template.tvo-testimonials-display-slider {
    width: 300px;
  }
  .thrlider-slider {
    height: auto;
    position: relative;
  }
  .tvo-set2-template.tve_orange .thrlider-nav .thrlider-navItem.thrlider-active .thrlider-navItem-inner {
    background: #666666;
  }
}

@media (max-width: 940px) {
  .tvo-set2-template.tvo-testimonials-display-slider .tvo-image-wrapper {
    min-width: 100%;
    margin-bottom: 10px;
  }
  .tvo-set2-template.tvo-testimonials-display-slider {
    padding: 0;
  }
}

@media (max-width: 768px) {
  .thrlider-nav {
    .thrlider-navItem {
    }
  }
}

@media (max-width: 540px) {
  .tvo-set2-template.tvo-testimonials-display-slider h4 {
    @include center-text;
  }
  .tvo-set2-template.tvo-testimonials-display-slider .tvo-testimonial-content {
    padding: 0 20px;
  }
  .tvo-set2-template.tvo-testimonials-display-slider {
    .tvo-image-wrapper, .tvo-testimonial-content {
      -webkit-flex-basis: 100%;
      flex-basis: 100%;
    }
  }
}
